package com.evl.common.persistence.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.evl.api.trainOrder.vo.PassengerRS;
import com.evl.api.trainOrder.vo.TrainOrderSearchRQ;
import com.evl.api.trainOrder.vo.TrainOrderSearchRS;
import com.evl.common.persistence.model.TrainOrder;

/**
 * <p>
  * 车票订单 Mapper 接口
 * </p>
 *
 * @author yangliwei
 * @since 2017-06-21
 */
public interface TrainOrderMapper extends BaseMapper<TrainOrder> {
	
	public Integer insertSelective(TrainOrder trainOrder);
	
	public List<TrainOrderSearchRS> findTrainOrders(TrainOrderSearchRQ rq);
	
	public TrainOrder selectTrainOrderByNo(@Param("orderNo")String  orderNo);
	
	public List<TrainOrder> selectTrainOrderList(TrainOrder order);
	
	public List<PassengerRS> findOrderPassengerDetail(@Param("id")Integer id);
	
	public List<TrainOrder> findUnPayOrders();
	
	public int addUpPayRecord(@Param("orderList")List<TrainOrder> list,@Param("desc")String content);
	
	public int addRecord(@Param("order")TrainOrder order,@Param("desc")String content,@Param("status")String status);
	
	public int invalidOrder(List<TrainOrder> list);
	
	public int updateOrderStatus(@Param("orderId") Integer orderId,@Param("status")Integer status);
	
}
